package com.edu.zju.scs.panacea.mapper.manage;


import com.edu.zju.scs.panacea.entity.manage.Admin;
import com.edu.zju.scs.panacea.entity.resource.Site;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface AdminMapper {
    @Select("SELECT * FROM admin WHERE name = #{name} and password = #{password}")
    @Results({
            @Result(id=true,property="id",column="id"),
            @Result(property="ownId",column="own_id"),
            @Result(property="name",column="name"),
            @Result(property="password",column="password")})
    Admin selectAdmin(String name, String password);
}
